﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;

namespace QLKS.Models
{
    static public class BaoCaoModel
    {
        //Lấy báo cáo
        static public DataSet GetBaoCaoDoanhThuTheoLoaiPhong(int nam, int thang)
        {
            return DataProviderModel.QueryResults("Exec sp_BCDoanhThuTheoLoaiPhong " + nam + "," + thang);
        }

        static public DataTable GetBaoCaoMatDoSuDungPhong(int nam, int thang)
        {
            return DataProviderModel.QueryResults("Exec sp_BCMatDoSuDungPhong " + nam + "," + thang).Tables[0];
        }
        //Chi tiết báo cáo
        static public DataTable GetChiTietBCDoanhThuTheoLoaiPhong(int nam, int thang, int malp)
        {
            return DataProviderModel.QueryResults("Exec sp_ChiTietBCDoanhThuTheoLoaiPhong " + nam + "," + thang + "," + malp).Tables[0];
        }

        static public DataTable GetChiTietBCMatDoSuDungPhong(int nam, int thang, string maphong)
        {
            return DataProviderModel.QueryResults("Exec sp_ChiTietBCMatDoSuDungPhong " + nam + "," + thang + "," + maphong).Tables[0];
        }
    }
}
